<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>导航显示</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        html{
            font-size: 25px !important;
        }
        ul{
            display: flex;
            list-style: none;
        }
        li{
            width: 93.75px;
            height: 30px;
            background-color: burlywood;
        }
        a{
            text-decoration: none;
            width: 100%;
            height: 100%;
        }
        @media screen and (min-width:768px) {
            section{
                margin: 0 auto;
                width: 750px;
            }
        }
        @media screen and (max-width:767px) {
            section{
                margin: 0 auto;
                width: 100%;
            }
            ul{
                flex-wrap: wrap;
            }
            li{
                width: 33.33%;
            }
        }
    </style>
</head>
<body>
    <section>
        <ul>
            <li><a href="#">导航1</a></li>
            <li><a href="#">导航2</a></li>
            <li><a href="#">导航3</a></li>
            <li><a href="#">导航4</a></li>
            <li><a href="#">导航5</a></li>
            <li><a href="#">导航6</a></li>
            <li><a href="#">导航7</a></li>
            <li><a href="#">导航8</a></li>
        </ul>
    </section>
</body>
</html>